package com.kang.bean;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.util.Date;

@Data       //get/set方法
@AllArgsConstructor     //构造方法
@NoArgsConstructor      //无参构造方法
public class Play {
    @NotEmpty(message = "id未填")
    private String id;

    @NotEmpty(message = "设备名未填")
    private String name;

    @NotNull(message = "限乘人数未填")
    private Integer permax;     //单次最大可使用人数

    @NotNull(message = "类型未选")
    private Integer typeid;     //分类id

    @NotNull(message = "运行状态未选择")
    private Integer running;    //是否在运行状态 1：运行 0：未运行

    @NotNull(message = "设备状态未选择")
    private Integer statusid;   //设备状态id

    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date date;      //设备安装日期

    private Integer time; // 运行时间

    private Long top;
    private String picid;

    private String info;
    private String suitable;
    private Integer stimulus;

}
